<include file="Public:header" />
<include file="Public:left" />

<style>
td,th{text-align:center;}
h2{line-height: 42px;}
</style>
<section>
	<div class="page_title">
    <h2 class="fl">砸金蛋奖品列表</h2>
    <a class="fr" href="{:url('activity/egg_add')}">新增奖品</a>
	</div>
	<table class="table">
		<tr>
        <th>奖品id</th>
		<th>奖品名称</th>
		<th>中奖概率</th>
        <th>排序</th>
		<th>操作</th>
		</tr>
		<volist name="data" id="vo">
		<tr>
		<td>{$vo['id']}</td>
		<td>{$vo.name}</td>
        <td>{$vo.odds}</td>
        <td>{$vo.sort}</td>
		<td>
			<a href="{:url('activity/egg_edit',array('id'=>$vo['id']))}" class="inner_btn">编辑</a>
			<a onclick="return confirm('确认删除？')" href="{:url('activity/egg_del',array('id'=>$vo['id']))}"  class="inner_btn" >删除</a>
		</td>
		</tr>
		</volist>
	</table>
	{$data->render()}
</section>
	<script>
	$(document).ready(function(){
		$(".admin_tab li a").click(function(){
		var liindex = $(".admin_tab li a").index(this);
		$(this).addClass("active").parent().siblings().find("a").removeClass("active");
		$(".admin_tab_cont").eq(liindex).fadeIn(150).siblings(".admin_tab_cont").hide();
		});
		});
	</script>
</body>
</html>
